package com.bird.设计模式.行为型.责任链模式.过滤器功能;

/**
 * @data 2022/10/5 17:17
 * @author: bird
 * @description:
 */
public class TestClient {
    public static void main(String[] args) {

        // 第一步：构建链条
        Handle.Builder builder = new Handle.Builder();
        builder.addBuilder(new ValidateHandler())
                .addBuilder(new LoginHandler())
                .addBuilder(new AuthHandler())
                .addBuilder(new BusinessLogicHandler());

        // 第二步：构建请求体
        Member member = new Member();
         member.setUserName("jack");
         member.setPassWord("666");
         member.setRoleName("管理员");
         builder.build().doHandle(member);


    }
}
